#include "S3C6410H264EncoderFilter.h"
#include "BaseNotification.h"

using namespace cm_base;
namespace cm_media
{
    int S3C6410H264EncoderInputPin::receive(ByteBuffer* p_data)
    {
        ((S3C6410H264EncoderFilter*)m_parent)->enqueueBuffer(p_data);

        return CmMediaSucess;
    }

    S3C6410H264EncoderFilter::S3C6410H264EncoderFilter()
    {

    }

    S3C6410H264EncoderFilter::~S3C6410H264EncoderFilter()
    {

    }


    int S3C6410H264EncoderFilter::setup()
    {
        return CmMediaFail;
    }

    int S3C6410H264EncoderFilter::enqueueBuffer(ByteBuffer* p_buffer)
    {
        return CmMediaFail;
    }

    int S3C6410H264EncoderFilter::teardown()
    {
        return CmMediaFail;
    }


    void S3C6410H264EncoderFilter::run()
    {
        BaseNotification* p_bn = NULL;
        while( !m_stopFlag ){

            p_bn = (BaseNotification*) waitDequeueNotification(0);
            if( p_bn ){
                switch( p_bn->getType() )
                {

                }
            }
            p_bn = NULL;
        }

    }

}